Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pmp/extracted pmp master #2528

Merged

Conversation

OlivierBetschi
Copy link
Contributor

Extraction of the PMP outside of the MMU. Replacement of PR2476

Comment on lines 306 to 309
assign mmu_exception = pmp_exception;
assign icache_areq_o = pmp_icache_areq_o;
assign translation_valid = pmp_translation_valid;
assign mmu_paddr = pmp_paddr;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[verible-verilog-format] reported by reviewdog 🐶

Suggested change
assign mmu_exception = pmp_exception;
assign icache_areq_o = pmp_icache_areq_o;
assign translation_valid = pmp_translation_valid;
assign mmu_paddr = pmp_paddr;
assign mmu_exception = pmp_exception;
assign icache_areq_o = pmp_icache_areq_o;
assign translation_valid = pmp_translation_valid;
assign mmu_paddr = pmp_paddr;

Comment on lines 333 to 364
.CVA6Cfg (CVA6Cfg),
.icache_areq_t(icache_areq_t),
.icache_arsp_t(icache_arsp_t),
.exception_t (exception_t)
) i_pmp_data_if (
.clk_i (clk_i),
.rst_ni (rst_ni),
.enable_translation_i (enable_translation_i),
.enable_g_translation_i(enable_g_translation_i),
.en_ld_st_translation_i(en_ld_st_translation_i),
.en_ld_st_g_translation_i(en_ld_st_g_translation_i),
.icache_areq_i (icache_areq_i),
.icache_areq_o (pmp_icache_areq_o),
.misaligned_ex_i (misaligned_exception),
.lsu_req_i (translation_req),
.lsu_vaddr_i (mmu_vaddr),
.lsu_tinst_i(mmu_tinst),
.lsu_is_store_i (st_translation_req),
.lsu_valid_o (pmp_translation_valid),
.lsu_paddr_o (pmp_paddr),
.lsu_exception_o (pmp_exception),
.priv_lvl_i (priv_lvl_i),
.v_i (v_i),
.ld_st_priv_lvl_i (ld_st_priv_lvl_i),
.ld_st_v_i (ld_st_v_i),
.pmpcfg_i (pmpcfg_i),
.pmpaddr_i (pmpaddr_i),
.data_allow_o (pmp_data_allow),
.instr_allow_o (pmp_instr_allow),
.match_any_execute_region_o (match_any_execute_region),
.misaligned_ex_o (pmp_misaligned_ex)
);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[verible-verilog-format] reported by reviewdog 🐶

Suggested change
.CVA6Cfg (CVA6Cfg),
.icache_areq_t(icache_areq_t),
.icache_arsp_t(icache_arsp_t),
.exception_t (exception_t)
) i_pmp_data_if (
.clk_i (clk_i),
.rst_ni (rst_ni),
.enable_translation_i (enable_translation_i),
.enable_g_translation_i(enable_g_translation_i),
.en_ld_st_translation_i(en_ld_st_translation_i),
.en_ld_st_g_translation_i(en_ld_st_g_translation_i),
.icache_areq_i (icache_areq_i),
.icache_areq_o (pmp_icache_areq_o),
.misaligned_ex_i (misaligned_exception),
.lsu_req_i (translation_req),
.lsu_vaddr_i (mmu_vaddr),
.lsu_tinst_i(mmu_tinst),
.lsu_is_store_i (st_translation_req),
.lsu_valid_o (pmp_translation_valid),
.lsu_paddr_o (pmp_paddr),
.lsu_exception_o (pmp_exception),
.priv_lvl_i (priv_lvl_i),
.v_i (v_i),
.ld_st_priv_lvl_i (ld_st_priv_lvl_i),
.ld_st_v_i (ld_st_v_i),
.pmpcfg_i (pmpcfg_i),
.pmpaddr_i (pmpaddr_i),
.data_allow_o (pmp_data_allow),
.instr_allow_o (pmp_instr_allow),
.match_any_execute_region_o (match_any_execute_region),
.misaligned_ex_o (pmp_misaligned_ex)
);
.CVA6Cfg (CVA6Cfg),
.icache_areq_t(icache_areq_t),
.icache_arsp_t(icache_arsp_t),
.exception_t (exception_t)
) i_pmp_data_if (
.clk_i (clk_i),
.rst_ni (rst_ni),
.enable_translation_i (enable_translation_i),
.enable_g_translation_i (enable_g_translation_i),
.en_ld_st_translation_i (en_ld_st_translation_i),
.en_ld_st_g_translation_i (en_ld_st_g_translation_i),
.icache_areq_i (icache_areq_i),
.icache_areq_o (pmp_icache_areq_o),
.misaligned_ex_i (misaligned_exception),
.lsu_req_i (translation_req),
.lsu_vaddr_i (mmu_vaddr),
.lsu_tinst_i (mmu_tinst),
.lsu_is_store_i (st_translation_req),
.lsu_valid_o (pmp_translation_valid),
.lsu_paddr_o (pmp_paddr),
.lsu_exception_o (pmp_exception),
.priv_lvl_i (priv_lvl_i),
.v_i (v_i),
.ld_st_priv_lvl_i (ld_st_priv_lvl_i),
.ld_st_v_i (ld_st_v_i),
.pmpcfg_i (pmpcfg_i),
.pmpaddr_i (pmpaddr_i),
.data_allow_o (pmp_data_allow),
.instr_allow_o (pmp_instr_allow),
.match_any_execute_region_o(match_any_execute_region),
.misaligned_ex_o (pmp_misaligned_ex)
);

Copy link
Contributor

❌ failed run, report available here.

1 similar comment
Copy link
Contributor

❌ failed run, report available here.

Copy link
Contributor

❌ failed run, report available here.

@OlivierBetschi OlivierBetschi force-pushed the pmp/extracted_pmp_master branch from 568177b to e4cca2c Compare November 20, 2024 16:15
Copy link
Contributor

❌ failed run, report available here.

@OlivierBetschi OlivierBetschi force-pushed the pmp/extracted_pmp_master branch from e4cca2c to f88bc36 Compare November 20, 2024 16:54
Copy link
Contributor

❌ failed run, report available here.

Copy link
Contributor

❌ failed run, report available here.

.gitlab-ci.yml Outdated
@@ -132,7 +132,7 @@ build_tools:

.simu_after_script: &simu_after_script
- for i in $(find verif/sim/out*/[vq]*_sim -type f \( -name "*.csv" -o -name "*.iss" -o -name "*.yaml" \)) ; do head -10000 $i > artifacts/logs/$(basename $i).head ; done
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
- for i in $(find verif/sim/out*/[vq]*_sim -type f \( -name "*.csv" -o -name "*.iss" -o -name "*.yaml" \)) ; do head -10000 $i > artifacts/logs/$(basename $i).head ; done
- for i in $(find verif/sim/out*/[vq]*_sim -type f \( -name "*.csv" -o -name "*.iss" -o -name "*.yaml" \)) ; do head -20000 $i > artifacts/logs/$(basename $i).head ; done

@valentinThomazic
Copy link
Contributor

valentinThomazic commented Nov 27, 2024

Hey @OlivierBetschi , I saw there was an issue with the dashboard not showing your logfiles.
Here are the logfiles for the failing generated test:
output
tb log
dasm
(bonus) tandem report

@yanicasa
Copy link
Contributor

Seems ok in principle! but the fail pattern needs to be fixed to validate this functionality as it challenges a lot the LSU exceptions

Copy link
Contributor

github-actions bot commented Dec 3, 2024

❌ failed run, report available here.

3 similar comments
Copy link
Contributor

github-actions bot commented Dec 3, 2024

❌ failed run, report available here.

Copy link
Contributor

github-actions bot commented Dec 3, 2024

❌ failed run, report available here.

Copy link
Contributor

github-actions bot commented Dec 3, 2024

❌ failed run, report available here.

@valentinThomazic
Copy link
Contributor

@OlivierBetschi I have manually rerun the smoke gen tests and it passed this time.
The asic synthesis fails because a patch needs update on our side.
Spyglass job also fails because the count of W123 : "A signal or variable has been read but is not set" increased from 11 to 12 on your commit.
I fixed the patch and will suggest the modifications to you

@valentinThomazic
Copy link
Contributor

valentinThomazic commented Dec 3, 2024

I am not able to propose changes since the file is not changed on your PR, here is a patch:

diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 048e75324..16ed6ac36 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -275,7 +275,7 @@ asic-synthesis:
     - echo $DV_TARGET
     - source ./verif/sim/setup-env.sh
     - git clone ${SYNTH_SCRIPT} ${SYNTH_SCRIPT_PATH} -b ${SYNTH_SCRIPT_BRANCH}
-    - git -C ${SYNTH_SCRIPT_PATH} checkout 1e166766d2c91ca905577cccc70813a2a8bbefc2
+    - git -C ${SYNTH_SCRIPT_PATH} checkout cce5ea41
     - cp -r ${SYNTH_SCRIPT_PATH}/cva6/ ../
     - git apply ${SYNTH_SCRIPT_PATH}/patches/*.patch
     - echo $SYN_DCSHELL_BASHRC; source $SYN_DCSHELL_BASHRC
@@ -546,7 +546,7 @@ simu-gate:
     - echo $PERIOD
     - source ./verif/sim/setup-env.sh
     - git clone ${SYNTH_SCRIPT} ${SYNTH_SCRIPT_PATH} -b ${SYNTH_SCRIPT_BRANCH}
-    - git -C ${SYNTH_SCRIPT_PATH} checkout 1e166766d2c91ca905577cccc70813a2a8bbefc2
+    - git -C ${SYNTH_SCRIPT_PATH} checkout cce5ea41
     - cp -r ${SYNTH_SCRIPT_PATH}/cva6/ ../
     - git apply ${SYNTH_SCRIPT_PATH}/patches/*.patch
     - source verif/regress/install-riscv-tests.sh

Please apply, commit and push it on your branch

@OlivierBetschi
Copy link
Contributor Author

@valentinThomazic thanks, I added your patch for gitlab. I can fix the spyglass issue if you give me the message, as I do not see the spyglass reports in the provided logs

Copy link
Contributor

github-actions bot commented Dec 3, 2024

❌ failed run, report available here.

@valentinThomazic
Copy link
Contributor

valentinThomazic commented Dec 3, 2024

@OlivierBetschi

W123 : Following Bits of signal 'pmp_paddr' (File Name: /gitlab-runner/runner_riscv-public/builds/yD5zmwgi3/0/riscv-ci/cva6/core/load_store_unit.sv Line No.: 356) are read but not set
	[33:12]	

The asic synthesis is working, it is considered failed because the gate count is different than the expected one.

Everything should pass if you fix the spyglass error and update .gitlab-ci/expected_synth.yml to match the new gate count.

Copy link
Contributor

github-actions bot commented Dec 3, 2024

❌ failed run, report available here.

@OlivierBetschi
Copy link
Contributor Author

@valentinThomazic I updated the RTL. Hopefully the spyglass is cleaner now. But i get the unaligned load store failed again. How should we proceed ? do you think we merge regardless or do you want to fix #2645 to be sure ?

Copy link
Contributor

github-actions bot commented Dec 3, 2024

❌ failed run, report available here.

@valentinThomazic
Copy link
Contributor

@OlivierBetschi I ran another pipeline manually but there are issues that should be addressed first.
I will let @JeanRochCoulon decide if it is ok to merge or not when the PR is fixed

@JeanRochCoulon
Copy link
Contributor

Synthesis is failed, gate simulation is failed: errors can be collected at the end of synthesis CI log
image

Copy link
Contributor

github-actions bot commented Dec 4, 2024

✔️ successful run, report available here.

@OlivierBetschi
Copy link
Contributor Author

@JeanRochCoulon the remaining issues in the CI are fixed. Thank you for your help @valentinThomazic

@JeanRochCoulon
Copy link
Contributor

Great job @OlivierBetschi We can merge !

@JeanRochCoulon JeanRochCoulon merged commit 23355d2 into openhwgroup:master Dec 4, 2024
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants